package com.jpx.jxcbiz.service.impl;

import com.jpx.common.dto.PurchaseDto;
import com.jpx.jxcbiz.entity.TPurchaseList;
import com.jpx.jxcbiz.mapper.TPurchaseListMapper;
import com.jpx.jxcbiz.service.ITPurchaseListService;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import com.jpx.jxcbiz.vo.PurchaseReceiptQuery;
import com.jpx.jxcbiz.vo.PurchaseTJDto;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author Mht
 * @since 2020-02-24
 */
@Service
public class TPurchaseListServiceImpl extends ServiceImpl<TPurchaseListMapper, TPurchaseList> implements ITPurchaseListService {

    @Autowired
    TPurchaseListMapper purchaseListMapper;

    @Override
    public List<PurchaseReceiptQuery> PurchaseReceiptQuery(PurchaseDto purchaseDto) {
        return purchaseListMapper.PurchaseReceiptQuery(purchaseDto);
    }

    @Override
    public void save(TPurchaseList purchaseList) {
        purchaseListMapper.save(purchaseList);
    }

    @Override
    public List findByPurchase(PurchaseTJDto purchaseTJDto) {
        return purchaseListMapper.findByPurchase(purchaseTJDto);
    }

    @Override
    public List findByReturn(PurchaseTJDto purchaseTJDto) {
        return purchaseListMapper.findByReturn(purchaseTJDto);
    }

    @Override
    public List getGoodsType() {
        return purchaseListMapper.getGoodsType();
    }
}
